<?

require_once "../init.php";

class Qi_Info_Exportar
{
	public static function salvar($arquivo = null)
	{
		$array = Qi_Info_Extensions::todas();
		$array["general"] = Qi_Info_Static::phpinfo_general();
		$serial = serialize($array);
		if ($arquivo)
			file_put_contents($arquivo, $serial);
		return $array;
	}

	public static function load($file)
	{
		$serial = file_get_contents($file);
		return unserialize($serial);
	}
}

header("Content-Type: text/plain");
$file = "compress.zlib://local.serialize.php";
Qi_Info_Exportar::salvar($file);
$array = Qi_Info_Exportar::load($file);
print_r($array);

?>